package com.lyfei.yd.domain.entity;

import com.baomidou.mybatisplus.annotation.TableField;
import com.baomidou.mybatisplus.annotation.TableName;
import com.lyfei.yd.domain.BaseEntity;
import lombok.Getter;
import lombok.Setter;
import lombok.experimental.Accessors;

import java.util.ArrayList;
import java.util.List;

@Getter
@Setter
@Accessors(chain = true)
@TableName("t_sys_menu")
public class SysMenu extends BaseEntity<SysMenu> {

    /**
     * 菜单名称
     */
    private String menuName;

    /**
     * 父菜单ID
     */
    private Long parentId;

    /**
     * 显示顺序
     */
    private Integer orderNum;

    /**
     * 路由地址
     */
    private String path;

    /**
     * 组件路径
     */
    private String component;

    /**
     * 菜单类型（M目录 C菜单）
     */
    private String menuType;

    /**
     * 是否隐藏
     */
    private Boolean hidden;

    /**
     * 菜单图标
     */
    private String icon;

    @TableField(exist = false)
    private List<SysMenu> children = new ArrayList<>();

}
